package day04;

import java.util.Random;
import java.util.Scanner;

public class ForDemo {
    static int sum;

    public static void main(String[] args) {

        /*Random rand = new Random();
        Scanner scanner = new Scanner(System.in);
        System.out.println("请输入一个数");
        int guessin = scanner.nextInt();

        int num = (int) (Math.random() * 1000 + 1);

        for (int i = 1; guessin != num; i++) {
            if (guessin > num) {
                System.out.println("猜大了");
            } else {
                System.out.println("猜小了");
            }
            System.out.println("请重新输入");
            guessin = scanner.nextInt();
            sum = i + 1;
        }

        System.out.println("恭喜你答对了！总共回答了" + sum + "次");*/

        /*for (int i = 1; i <= 9; i++) {
            for (int j = 1; j <= i; j++) {
                System.out.printf(i + "*" + j + "=" + (i * j) + "\t");
            }
            System.out.println();
        }*/
       /* for (int i = 1; i <= 100; i++) {
            sum += i;
        }
        System.out.println(sum);*/
        for(int i=1;i<=100;i++)
            System.out.print(i+" ");
    }
}
